local skel = fk.CreateSkill {
  name = "sj_zhoushuhuizhan__jizhifanyun",
}

Fk:loadTranslationTable{
  ["sj_zhoushuhuizhan__jizhifanyun"] = "极之番陨",
  [":sj_zhoushuhuizhan__jizhifanyun"] = "出牌阶段限一次，你可以将一张牌当【火攻】使用，目标不能展示与之不同颜色的牌，你改为需弃置一张与上述两张牌花色不同的牌，若你或目标不能执行对应操作，则展示手牌并令你摸两张牌。",

  ["#sj_zhoushuhuizhan__jizhifanyun"] = "极之番陨：你可以将一张牌当【火攻】使用",
  ["#sj_zhoushuhuizhan__jizhifanyun-show"] = "%src 对你使用了火攻，请展示一张%arg手牌",
  ["#sj_zhoushuhuizhan__jizhifanyun-discard"] = "你须弃置一张不为 %arg 的手牌，对 %src 造成1点火属性伤害",

  ["$sj_zhoushuhuizhan__jizhifanyun1"] = "",
  ["$sj_zhoushuhuizhan__jizhifanyun2"] = "",
}


skel:addEffect("viewas", {
  pattern = "fire_attack",
  prompt = "#sj_zhoushuhuizhan__jizhifanyun",
  card_num = 1,
  min_card_num = 1,
  card_filter = function (self, player, to_select, selected, selected_targets)
    return #selected == 0
  end,
  view_as = function(self, player, cards)
    if #cards ~= 1 then return end
    local card = Fk:cloneCard("fire_attack")
    card.skillName = skel.name
    card.skill = Fk.skills["sj_zhoushuhuizhan__jizhifanyun_fire_attack_skill"]
    card:addSubcards(cards)
    return card
  end,
  enabled_at_play = function(self, player)
    return player:usedSkillTimes(skel.name,Player.HistoryPhase) < 1 and player.phase == Player.Play and not player:isNude()
  end,
  enabled_at_response = function (test, player, response)
    return not response and player:usedSkillTimes(skel.name,Player.HistoryPhase) < 1 and player.phase == Player.Play and not player:isNude()
  end,
})


return skel
